Imports System.Net
Imports System.Net.Sockets

Public Class Form1

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        Dim httpReq As System.Net.HttpWebRequest
        Dim httpResp As System.Net.HttpWebResponse
        Try
            Dim httpURL As New System.Uri(TextBox1.Text)

            httpReq = CType(WebRequest.Create(httpURL), HttpWebRequest)
            httpResp = CType(httpReq.GetResponse(), HttpWebResponse)

            TextBox2.Text = httpResp.CharacterSet.ToString
            TextBox3.Text = httpResp.ContentEncoding.ToString
            TextBox4.Text = httpResp.ContentLength.ToString
            TextBox5.Text = httpResp.ContentType.ToString
            TextBox6.Text = httpResp.LastModified.ToString
            TextBox7.Text = httpResp.Method.ToString
            TextBox8.Text = httpResp.ProtocolVersion.ToString
            TextBox9.Text = httpResp.ResponseUri.ToString
            TextBox10.Text = httpResp.Server.ToString
            TextBox11.Text = httpResp.StatusCode.ToString
            TextBox12.Text = httpResp.StatusDescription.ToString

        Catch ex As Exception
            Label12.Text = ex.StackTrace.ToString()
        End Try
    End Sub

    Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
        End
    End Sub
End Class
